﻿using System;

namespace LearnReadonlyAndConst
{
    class Program
    {
        static void Main(string[] args)
        {
            Console.WriteLine("Hello World!");

            const int ConstA = 10;
            //const int ConstB;

            Console.WriteLine(ConstA);
            //Console.WriteLine(ConstB);

            Test test = new Test();
            //test.ReadonlyA = 10;
            Console.WriteLine(test.ReadonlyA);
            
            Console.WriteLine(Test.ConstA);

            Console.ReadLine();
        }
    }

    class Test
    {
        public const int ConstA = 10;

        public readonly int ReadonlyA = 11;

        public Test()
        {
            ReadonlyA = 12;
        }
    }
}

